package com.aspose.cells.a.d;

import java.util.HashMap;

public class zfr {
   private String a;
   private HashMap b;

   public zfr(String var1) {
      this.a = var1;
      this.b = new HashMap();
   }

   public void a(zfq var1) {
      if (var1 == null) {
         throw new NullPointerException("font");
      } else {
         if (!com.aspose.cells.b.a.zv.b(var1.b(), this.a)) {
            ;
         }

         this.b.put(var1.g(), var1);
      }
   }

   public zfq a(int var1, boolean var2) {
      zfq var3 = (zfq)this.b.get(var1);
      if (var3 != null) {
         return var3;
      } else if (var2) {
         return null;
      } else {
         int var4 = var1 & -5;
         var3 = (zfq)this.b.get(var4);
         if (var3 != null) {
            return var3;
         } else {
            var4 = var1 & -9;
            var3 = (zfq)this.b.get(var4);
            if (var3 != null) {
               return var3;
            } else {
               var4 = var1 & -3;
               var3 = (zfq)this.b.get(var4);
               if (var3 != null) {
                  return var3;
               } else {
                  var4 = var1 & -2;
                  var3 = (zfq)this.b.get(var4);
                  if (var3 != null) {
                     return var3;
                  } else {
                     byte var5 = 1;
                     var3 = (zfq)this.b.get(Integer.valueOf(var5));
                     if (var3 != null) {
                        return var3;
                     } else {
                        var5 = 2;
                        var3 = (zfq)this.b.get(Integer.valueOf(var5));
                        return var3 != null ? var3 : (zfq)this.b.get(0);
                     }
                  }
               }
            }
         }
      }
   }
}
